home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Software Vault: The Gold Collection
/
Software Vault - The Gold Collection (American Databankers) (1993).ISO
/
cdr49
/
cport20.zip
/
README.!!!
< prev
next >
Wrap
Text File
|
1993-04-09
|
2KB
|
77 lines
This file contains important last minute information for Cport v2.0.
Please Take a moment to read it.
General
-------
- Traditionally header files of a library are included as they are
needed like so.
#include "cport.h"
#include "xmodem.h"
Problems sometimes arise when header files are not included in the
correct order. To remedy this situation we added an alternative way
of including header files. Instead of including each header file,
only cport.h needs to be included and symbols are defined to inform
cport.h to include certain files.
#define Uses_Xmodem
#include "cport.h"
'Uses_Xmodem' is currently the only symbol, but new ones will be
added as new features are added in subsequent versions.
- If you use the structure typedef 'CPARAM', make sure your compiler
is generating byte alignment. For Borland C/C++ and Microsoft C/C++
this is taken care of. For other compilers check your documentation.
C
_
- The documentation shows the function ComClose as returning 'void'.
It actually returns a NULL serial port handle (COM). This is so that
a serial port handle may be optionally NULLed when the serial port is
closed. NULLing a serial port handle can be used to mark it as unused.
Example:
int main()
{
COM com;
com = ComOpen(COM1, B19200, W8|S1|NONE, 1024, 512);
...later
/* Close the serial port and NULL the serial port handle
*/
com = ComClose(com);
... continued
C++
---
- Most C++ compilers pre-define the symbol '__cplusplus'. Cport
looks for this symbol to detect a C++ compile. If your C++ compiler
does not define this symbol, simply define it before you include
cport.h.
#define __cplusplus
#include "cport.h"